<?php
class pf {
	static private $autoloadClasses = array(
		'pfForm'  => 'pfForm/definition/Form.php',

		'pfField' => 'pfForm/definition/Field.php',
		'pfFieldInput'  => 'pfForm/definition/Input.php',
		'pfFieldSelect'  => 'pfForm/definition/Select.php',
		'pfFieldTextarea'  => 'pfForm/definition/Textarea.php',

		'pfRendererField' => 'pfForm/renderer/Field.php',
		'pfRendererHTML' => 'pfForm/renderer/HTML.php',
	);

	static public function autoload($class) {
		if (isset(self::$autoloadClasses[$class])) {
			$file =self::$autoloadClasses[$class];
			require_once $file;
			return $file;
		}
		return false;
	}

}


spl_autoload_register(array('pf', 'autoload'));
//autoloader registrieren